<?php
namespace App\Http\Controllers\Api\PrizeType;

use App\Http\Controllers\Controller;
use App\Models\PrizeType\PrizeTypeService;
use Illuminate\Http\Request;

class PrizeTypeController extends Controller
{
    public function query(Request $request, PrizeTypeService $prizeTypeService)
    {
        $result = $prizeTypeService->findList();
        if ($result) {
            return $this->respondJson(array('prize_types' => $result));
        }
        return $this->respondJson(array('prize_types' => array(), 'code' => 1));
    }
}
